﻿using HelpDeskTool.Entities.Devices;
using NUnit.Framework;

namespace HelpDeskToolTests;

[TestFixture]
public class StorageDiskTests
{
	[TestCase("Model", 500, ExpectedResult = "500 GB | Model")]
	[TestCase("Model", 8000, ExpectedResult = "8 TB | Model")]
	[TestCase("", 8192, ExpectedResult = "8 TB")]
	[TestCase(null, 8000, ExpectedResult = "8 TB")]
	[TestCase(" ", 8000, ExpectedResult = "8 TB")]
	[TestCase("\t\n", 8000, ExpectedResult = "8 TB")]
	[TestCase("Model", 0, ExpectedResult = "Model")]
	public string ToStringShouldBeFullOrPartial(string? modelName, int capacity)
	{
		var device = new StorageDisk
		{
			ModelName = modelName,
			Capacity = (uint)capacity
		};

		return device.ToString();
	}
}
